﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace SmartKeeper
{
    [AttributeUsage(AttributeTargets.Property)]
    public class ValueAttribute : Attribute
    {
        /// <summary>
        /// 是否为主键
        /// </summary>
        public bool Key { get; set; }

        /// <summary>
        /// 是否唯一
        /// </summary>
        public bool IsUnique { get; set; }
        /// <summary>
        /// 是否作为索引
        /// </summary>
        public bool IsIndex { get; set; }

        /// <summary>
        /// 字段类型
        /// </summary>
        public FieldType FieldType { get; set; }

        /// <summary>
        /// 是否支持排序
        /// </summary>
        public bool Sortable { get; set; }

        /// <summary>
        /// 是否从大到小
        /// </summary>
        public bool BigFirst { get; set; }
    }
}
